﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace University.Workshop.Presenters.Cistern.Read
{
    public class PresenterReadFirstStep
    {
        IFirstStepReadCistern view;
        public PresenterReadFirstStep(IFirstStepReadCistern view)
        {
            this.view = view;
        }

        public void UpdateData()
        {
            view.PersonId = view.CisternToRead.Person.PersonId;
            view.PersonNames = view.CisternToRead.Person.Names;
            view.PersonLastNames = view.CisternToRead.Person.LastNames;
            //ChargePhonesToList();
            view.PersonPhones = view.CisternToRead.Person.Phone.Split(',').Where(x => x != string.Empty).ToList();
        }
    }
}
